maximum sum of pairs with specific difference

welcome to shbcf.ru